package com.ruoyi.web.controller.app;

import com.ruoyi.app.domain.AppCaseInfo;
import com.ruoyi.app.domain.AppOperationLog;
import com.ruoyi.app.service.IAppOperationLogService;
import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.common.utils.DateUtils;
import com.ruoyi.common.utils.StringUtils;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@Api(value="APP消息",tags={"APP消息"})
@RequestMapping("app/log")
@RestController
public class AppOperationLogController extends  AppBaseController{

    @Autowired
    private IAppOperationLogService iAppOperationLogService;

    @GetMapping("/page")
    @ApiOperation(value = "消息分页列表",response= AppOperationLog.class)
    @ApiImplicitParams({
            @ApiImplicitParam(name = "X-TaiChi-Token", value = "apyexnioxzsa11cqxy2ur2p9jkp46hz7",
                    paramType = "header", dataType = "string", required = true),
            @ApiImplicitParam(name="pageNum",value="当前记录起始索引",required=true ),
            @ApiImplicitParam(name="pageSize",value="每页显示记录数",required=true),
            @ApiImplicitParam(name="orderByColumn",value="排序列"),
            @ApiImplicitParam(name="isAsc",value="排序的方向 \"desc\" 或者 \"asc\""),
    })
    public AjaxResult list(){
        startPage();
        List<AppOperationLog> list = iAppOperationLogService.selectAppOperationLogList(null);
        return AjaxResult.success(getDataTable(list));
    }


}
